/* =====================================================
LAYOUT STYLES: Header, Footer, Navigation, Containers
Extracted from catalog.html for Phase 3.2
===================================================== */

/* =====================================================
HEADER / LOGO SECTION - PROFESSIONAL FIXED NAV BAR
Based on Apple HIG and Modern App Design Principles
===================================================== */
.app-header {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    transform: none !important;
    z-index: 1000; /* High z-index to stay above content */
    /* App header wrapper is transparent; nav bar background is a short layer */
    background: transparent;
    border-bottom: none;
    box-shadow: none;
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
    /* Safe area support for notched devices */
    padding-top: env(safe-area-inset-top, 0px);
    /* Nav bar height (used by background layer) */
    --nav-h: 56px;
    /* Professional transition for scroll effects */
    transition: box-shadow 0.2s ease, background 0.2s ease;
    /* Modern edge-to-edge design with clean boundaries */
    overflow: visible;
}

/* Decorative geometric shapes overlay */
.app-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: auto;
    pointer-events: none;
    z-index: 0;
    opacity: 0.32;
    height: calc(var(--nav-h) + env(safe-area-inset-top, 0px));
    /* Soft mint shapes + subtle stripes (premium) */
    background-image: 
        /* Base mint gradient (short, behind nav only) */
        linear-gradient(to right,
            #FFFFFF 0%,
            #F6FFFB 20%,
            #EFFFF7 48%,
            #E7F9F0 74%,
            #F9FFFC 100%
        ),
        /* Soft diagonal stripes */
        repeating-linear-gradient(135deg,
            rgba(16, 185, 129, 0.10) 0px,
            rgba(16, 185, 129, 0.10) 6px,
            rgba(255, 255, 255, 0) 6px,
            rgba(255, 255, 255, 0) 18px
        ),
        /* Soft green circle - top center */
        radial-gradient(circle at 50% 20%, rgba(16, 185, 129, 0.22) 0%, rgba(16, 185, 129, 0.22) 15%, transparent 15%),
        /* "3D" bubble - top right (highlight + shadow feel) */
        radial-gradient(circle at 88% 28%,
            rgba(255, 255, 255, 0.55) 0%,
            rgba(209, 250, 229, 0.38) 22%,
            rgba(16, 185, 129, 0.14) 46%,
            transparent 62%
        ),
        /* Mint square/diamond - mid right */
        linear-gradient(45deg, transparent 40%, rgba(167, 243, 208, 0.30) 40%, rgba(52, 211, 153, 0.18) 60%, transparent 60%),
        /* Teal bar - top left */
        linear-gradient(135deg, transparent 45%, rgba(20, 184, 166, 0.22) 45%, rgba(20, 184, 166, 0.22) 55%, transparent 55%);
    background-size: 
        100% 100%,    /* Base gradient */
        100% 100%,    /* Stripes */
        120px 120px,  /* Circle size */
        220px 220px,  /* 3D bubble */
        80px 80px,    /* Diamond size */
        200px 8px;    /* Bar size */
    background-position: 
        0% 0%,        /* Base gradient */
        0% 0%,        /* Stripes */
        50% 10%,      /* Circle position */
        100% 0%,      /* 3D bubble */
        85% 50%,      /* Diamond position */
        5% 15%;       /* Bar position */
    background-repeat: no-repeat;
}

.app-header::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: auto;
    pointer-events: none;
    z-index: 0;
    opacity: 0.30;
    height: calc(var(--nav-h) + env(safe-area-inset-top, 0px));
    /* White rounded shape - bottom left + extra 3D blob */
    background-image: 
        radial-gradient(ellipse at 10% 90%, rgba(255, 255, 255, 0.5) 0%, rgba(255, 255, 255, 0.5) 25%, transparent 25%),
        /* "3D" blob - bottom right */
        radial-gradient(ellipse at 92% 92%,
            rgba(255, 255, 255, 0.50) 0%,
            rgba(167, 243, 208, 0.28) 28%,
            rgba(16, 185, 129, 0.10) 52%,
            transparent 70%
        ),
        /* Mint triangle - bottom left */
        linear-gradient(135deg, transparent 50%, rgba(110, 231, 183, 0.22) 50%, transparent 70%),
        /* Teal bar - bottom center */
        linear-gradient(45deg, transparent 48%, rgba(20, 184, 166, 0.20) 48%, rgba(20, 184, 166, 0.20) 52%, transparent 52%),
        /* Teal bar - top right */
        linear-gradient(0deg, transparent 45%, rgba(20, 184, 166, 0.22) 45%, rgba(20, 184, 166, 0.22) 55%, transparent 55%);
    background-size: 
        150px 100px,  /* White shape */
        260px 220px,  /* 3D blob */
        100px 100px,  /* Triangle */
        180px 6px,    /* Bottom bar */
        120px 6px;    /* Top right bar */
    background-position: 
        0% 100%,      /* White shape */
        100% 100%,    /* 3D blob */
        5% 85%,       /* Triangle */
        50% 95%,      /* Bottom bar */
        90% 20%;      /* Top right bar */
    background-repeat: no-repeat;
}

.header-container {
    max-width: 1280px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--space-2) var(--space-4); /* Compact Apple-like nav bar */
    min-height: 56px; /* Standard iOS navigation bar height */
    /* Transparent to show parent gradient */
    background: transparent;
    /* Modern professional edges - refined separation */
    position: relative;
    z-index: 1; /* Above decorative shapes */
    /* Clean inner edges with subtle definition */
    border-left: 0.5px solid rgba(255, 255, 255, 0.2);
    border-right: 0.5px solid rgba(255, 255, 255, 0.2);
}

/* Professional separator line between header and sub-header (on coral background) */
.header-container::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 1px; /* More visible separator */
    /* Modern gradient edge - iOS hairline style with stronger visibility */
    background: linear-gradient(90deg, 
        rgba(255, 255, 255, 0) 0%, 
        rgba(255, 255, 255, 0.25) 10%, 
        rgba(255, 255, 255, 0.4) 50%, 
        rgba(255, 255, 255, 0.25) 90%, 
        rgba(255, 255, 255, 0) 100%);
    /* Enhanced shadow for clear separation */
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.08),
                0 0.5px 0 rgba(255, 255, 255, 0.1);
    z-index: 1;
}

/* Modern top edge highlight for professional look */
.header-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 0.5px;
    /* Subtle top highlight edge */
    background: linear-gradient(90deg, 
        rgba(255, 255, 255, 0) 0%, 
        rgba(255, 255, 255, 0.1) 50%, 
        rgba(255, 255, 255, 0) 100%);
}

/* Header Brand Group - Logo + Company Name (Left Side) */
.header-brand-group {
    display: flex;
    align-items: center;
    gap: var(--space-1); /* Reduced from space-3 to space-1 for closer logo + name */
    flex: 1;
    min-width: 0; /* Allow shrinking */
    position: relative;
    z-index: 1; /* Above decorative shapes */
}

.header-brand {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    cursor: pointer;
    transition: opacity 0.2s ease, transform 0.2s ease;
    -webkit-tap-highlight-color: transparent;
}

.header-brand:hover {
    opacity: 0.8;
    transform: scale(0.98);
}

.header-brand:active {
    transform: scale(0.96);
}

/* Logo Wrapper - Professional iOS style */
.header-logo-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    /* Minimal spacing from company name - logo and name appear side by side */
    margin-right: 0;
    /* Ensure wrapper always takes space - matches logo height (34px) */
    min-width: 34px;
    min-height: 34px;
    /* Remove any background from wrapper */
    background: transparent !important;
    padding: 0;
    border: none;
}

.header-logo {
    height: 34px; /* Increased by 2px from 32px - Standard iOS navigation bar icon size */
    width: auto;
    max-width: 120px; /* Prevent logo from being too wide */
    min-width: 24px; /* Minimum width to ensure visibility */
    display: none; /* Hidden by default, shown when logo loads */
    object-fit: contain;
    /* Professional image rendering */
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
    /* Smooth transitions */
    transition: opacity 0.2s ease, transform 0.2s ease;
    /* Ensure logo is visible when loaded */
    visibility: visible;
    opacity: 1;
    /* Remove white background from logo */
    /* Use mix-blend-mode to blend white backgrounds with the coral pink nav bar */
    /* darken mode: white pixels become transparent/blend with background, colored pixels stay visible */
    mix-blend-mode: darken;
    /* Ensure no background shows through */
    background: transparent !important;
    /* Remove any padding or border that might create white space */
    padding: 0 !important;
    border: none !important;
    /* Remove any box shadow that might create white appearance */
    box-shadow: none !important;
    /* Additional filter to help with white background removal */
    /* Increase contrast slightly to make white more distinct for blending */
    filter: contrast(1.05);
}

.header-logo:hover {
    opacity: 0.9;
}

/* Ensure logo loads properly - show even if initial load fails */
.header-logo[src=""] {
    display: none;
}

/* Handle image load errors gracefully - keep space reserved */
.header-logo:not([src]),
.header-logo[src=""],
.header-logo[src="logo.png"]:not([src*="http"]) {
    /* Keep the space but show a subtle placeholder on error */
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    min-width: 24px;
    min-height: 24px;
}

.header-title-group {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 0; /* Allow text truncation if needed */
    flex: 1;
}

.header-title-group h1 {
    font-size: 17px; /* iOS standard large title size */
    font-weight: 600;
    line-height: 1.2;
    color: rgba(17, 24, 39, 0.85); /* Dark text for readability on light gradient */
    margin: 0;
    letter-spacing: -0.02em; /* Tighter letter spacing for professional look */
    /* iOS-style font rendering */
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    /* Prevent text overflow */
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    /* Subtle text shadow for better readability on gradient */
    text-shadow: 0 1px 2px rgba(255, 255, 255, 0.8);
}

.header-title-group p {
    font-size: 12px;
    font-weight: 400;
    line-height: 1.2;
    color: var(--text-secondary);
    margin: 0;
    margin-top: 2px;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    flex-shrink: 0;
    margin-left: var(--space-2); /* Space from brand group */
    position: relative;
    z-index: 1; /* Above decorative shapes */
}

.header-brand-group {
    cursor: pointer;
    user-select: none;
    -webkit-user-select: none;
    touch-action: manipulation;
}

.header-brand-group:active {
    transform: scale(0.995);
}

.header-desktop-link {
    font-size: 12px;
    font-weight: 500;
    color: #374151;
    padding: 6px 8px;
    border-radius: 999px;
    border: 1px solid rgba(55, 65, 81, 0.15);
    background: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    touch-action: manipulation;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 32px;
    min-height: 32px;
}

.header-desktop-icon {
    width: 18px;
    height: 18px;
    display: block;
}

.header-desktop-link:hover {
    background: #f9fafb;
}

/* Search Section (below category, above products) */
.search-section {
    max-width: 1280px;
    margin: 0 auto;
    /* tighter vertical spacing */
    padding: var(--space-2) var(--space-4) var(--space-2);
    background: transparent;
    border-bottom: 0.5px solid rgba(0, 0, 0, 0.08);
    position: relative;
    z-index: 998;
}

/* Search Input Wrapper */
.search-input-wrapper-inline {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: var(--radius-lg);
    padding: var(--space-2) var(--space-4);
    width: 100%;
    max-width: 100%;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    transition: all 0.2s ease;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.search-input-wrapper-inline:focus-within {
    background: rgba(255, 255, 255, 1);
    border-color: var(--brand-teal, #469291);
    box-shadow: 0 0 0 3px rgba(70, 146, 145, 0.1), 0 2px 4px rgba(0, 0, 0, 0.08);
}

.search-input-icon {
    width: 18px;
    height: 18px;
    color: var(--text-secondary);
    flex-shrink: 0;
    transition: opacity 0.15s ease;
}

/* Hide search icon while typing (gives input more room) */
.search-input-wrapper-inline.search-has-text .search-input-icon {
    display: none;
}

.search-input-field-inline {
    flex: 1;
    border: none;
    background: transparent;
    font-size: 15px;
    color: var(--text-primary);
    outline: none;
    padding: 0;
    min-width: 0;
}

.search-input-field-inline::placeholder {
    color: var(--text-secondary);
    opacity: 0.7;
}

/* Search: secondary toggles row (outside the input) */
.search-subtoggles {
    margin-top: 6px;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 10px;
    padding: 0 4px;
}

/* When a toggle is outside the input, remove the divider styling */
.search-subtoggles .collections-only-inline {
    margin-left: 0;
    padding-left: 0;
    border-left: 0;
}

.search-close-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 20px;
    cursor: pointer;
    padding: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s ease;
    flex-shrink: 0;
}

.search-close-btn:hover {
    background: rgba(0, 0, 0, 0.05);
    color: var(--text-primary);
}

.search-close-btn:active {
    transform: scale(0.9);
}

.header-info-btn {
    background: transparent;
    border: none;
    border-radius: var(--radius-md);
    padding: var(--space-1);
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s var(--ease-stripe);
    opacity: 0.6;
    margin-left: var(--space-2);
}

.header-info-btn:hover {
    opacity: 1;
    color: var(--brand-teal);
    background: rgba(70, 146, 145, 0.1);
}

.header-info-btn:active {
    transform: scale(0.95);
}

.header-info-btn svg {
    width: 16px;
    height: 16px;
}

.terms-header-btn {
    background: #489292;
    border: 1px solid #489292;
    border-radius: var(--radius-md);
    padding: var(--space-2) var(--space-3);
    color: #FFFFFF;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s var(--ease-stripe);
    min-width: 44px;
    height: 44px;
}

.terms-header-btn:hover {
    background: #10B981; /* Emerald */
    border-color: #10B981;
    color: #FFFFFF;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(16, 185, 129, 0.28);
}

.terms-header-btn:active {
    transform: translateY(0);
    box-shadow: 0 1px 4px rgba(16, 185, 129, 0.22);
}

.terms-header-btn svg {
    width: 20px;
    height: 20px;
    stroke: #FFFFFF;
}

/* Search Header Button - Icon Button Style (on gradient background) */
.search-header-btn {
    background: rgba(255, 255, 255, 0.6); /* Semi-transparent white on light gradient */
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: var(--radius-md);
    padding: var(--space-2);
    color: rgba(17, 24, 39, 0.7); /* Dark icon for visibility on light gradient */
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s var(--ease-stripe);
    min-width: 44px;
    min-height: 44px;
    margin-right: var(--space-2);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.search-header-btn:hover {
    background: rgba(255, 255, 255, 0.8);
    color: rgba(17, 24, 39, 0.9);
    border-color: rgba(0, 0, 0, 0.15);
}

.search-header-btn:active {
    transform: scale(0.95);
}

.search-header-btn svg {
    width: 22px;
    height: 22px;
    stroke: currentColor;
}

.cache-clear-btn {
    background: rgba(255, 237, 74, 0.2); /* Yellow tint for cache button */
    border: 1px solid rgba(255, 237, 74, 0.4);
}

.cache-clear-btn:hover {
    background: rgba(255, 237, 74, 0.3);
    border-color: rgba(255, 237, 74, 0.6);
}

/* Category Filter Button - Sub-Header with Clear Professional Separation */
.category-filter-container {
    /* Separate floating filter surface (Apple-like) */
    padding: 0;
    margin: 0;
    background: rgba(255, 255, 255, 0.86);
    border: 1px solid rgba(17, 24, 39, 0.08);
    border-radius: 22px;
    box-shadow:
        0 10px 30px rgba(17, 24, 39, 0.10),
        0 2px 10px rgba(17, 24, 39, 0.06),
        0 1px 0 rgba(255, 255, 255, 0.70) inset;
    /* In-flow within fixed header (spacing handled by body padding) */
    position: relative;
    z-index: 2;
    /* Light backdrop blur for iOS-like effect */
    backdrop-filter: blur(14px) saturate(180%);
    -webkit-backdrop-filter: blur(14px) saturate(180%);
    /* Allow horizontal scrolling */
    overflow-x: auto;
    overflow-y: hidden;
    /* Hide scrollbar for cleaner look */
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE/Edge */
    /* Smooth scrolling */
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
}

/* Hide scrollbar for WebKit browsers */
.category-filter-container::-webkit-scrollbar {
    display: none;
}

/* Horizontal scrollable chips container */
.category-chips-scroll {
    display: flex;
    align-items: center;
    gap: var(--space-2);
    padding: var(--space-2) var(--space-2);
    min-width: min-content; /* Allow content to determine width */
}

/* Individual category chip */
.category-chip {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: var(--space-2) var(--space-4);
    min-height: 36px;
    border-radius: 18px; /* Pill shape */
    font-size: 14px;
    font-weight: 500;
    white-space: nowrap;
    cursor: pointer;
    transition: all 0.2s var(--ease-stripe);
    flex-shrink: 0; /* Prevent chips from shrinking */
    /* Inactive state - light background */
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(0, 0, 0, 0.08);
    color: rgba(17, 24, 39, 0.7);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

/* Active chip state - mint/green */
.category-chip.active {
    background: linear-gradient(135deg, #10B981 0%, #14B8A6 100%);
    border-color: rgba(16, 185, 129, 0.95);
    color: #FFFFFF;
    box-shadow: 0 2px 8px rgba(16, 185, 129, 0.28), 0 1px 4px rgba(20, 184, 166, 0.18);
    font-weight: 600;
}

/* Sale chip special styling */
.category-chip.category-chip-sale {
    background: rgba(255, 255, 255, 0.7);
    border: 1px solid rgba(0, 0, 0, 0.08);
    color: rgba(17, 24, 39, 0.7);
}

.category-chip.category-chip-sale.active {
    background: linear-gradient(135deg, #10B981 0%, #14B8A6 100%); /* Mint gradient */
    border-color: rgba(16, 185, 129, 0.95);
    color: #FFFFFF;
    box-shadow: 0 2px 8px rgba(16, 185, 129, 0.28);
}

/* Hover states */
.category-chip:hover:not(.active) {
    background: rgba(255, 255, 255, 0.9);
    border-color: rgba(0, 0, 0, 0.12);
    color: rgba(17, 24, 39, 0.9);
    transform: translateY(-1px);
}

.category-chip:active {
    transform: translateY(0) scale(0.98);
}

/* Touch-friendly sizing */
@media (max-width: 640px) {
    .category-chip {
        min-height: 40px; /* Larger touch target on mobile */
        padding: var(--space-2) var(--space-4);
        font-size: 13px;
    }
}

/* Old category filter button styles removed - now using chips */

@media (min-width: 640px) {
    .category-filter-container {
        left: var(--space-6);
        right: var(--space-6);
        margin-top: var(--space-3);
        border-radius: 24px;
        margin-bottom: 0 !important; /* Removed to prevent coral stripe */
        /* More spacing on larger screens (Apple HIG: 24px for tablet/desktop) */
        /* Spacing now handled by products-container margin-top */
    }
}

/* Cart Header Button - Modern Shopping App Style with Teal */
.cart-header-btn {
    position: relative;
    background: var(--gradient-primary, linear-gradient(135deg, #6B7280 0%, #9CA3AF 100%));
    border: 1px solid var(--brand-primary, #6B7280);
    border-radius: var(--radius-md);
    padding: var(--space-2);
    color: #FFFFFF;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s var(--ease-stripe);
    min-width: 44px;
    min-height: 44px;
    box-shadow: 0 2px 8px rgba(107, 114, 128, 0.25);
}

.cart-header-btn:hover {
    filter: brightness(0.9);
    color: #FFFFFF;
    box-shadow: 0 4px 12px rgba(107, 114, 128, 0.35);
    transform: translateY(-1px);
}

.cart-header-btn:active {
    transform: scale(0.95);
}

.cart-header-btn svg {
    width: 22px;
    height: 22px;
    stroke: #FFFFFF;
}

.cart-header-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    background: var(--gradient-accent, linear-gradient(135deg, #6B7280 0%, #9CA3AF 100%));
    color: #000;
    border-radius: 10px;
    min-width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: 700;
    padding: 0 5px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
    border: 2px solid #fff;
}

.cart-header-badge:empty {
    display: none;
}

/* Old Cart Header Button (keeping for reference) */
.cart-header-btn-old {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.cart-badge {
    position: absolute;
    top: -6px;
    right: -6px;
    background: var(--brand-teal);
    color: white;
    border-radius: 50%;
    width: 18px;
    height: 18px;
    font-size: 11px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cart-nav-badge {
    position: absolute;
    top: 2px;
    right: 2px;
    background: var(--brand-teal);
    color: white;
    border-radius: 50%;
    min-width: 18px;
    height: 18px;
    font-size: 10px;
    font-weight: 600;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    border: 2px solid rgba(255, 255, 255, 0.9);
}

.cart-info-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: rgba(70, 146, 145, 0.15);
    color: var(--brand-teal);
    cursor: pointer;
    transition: all 0.2s;
    flex-shrink: 0;
}

.cart-info-icon:hover {
    background: rgba(70, 146, 145, 0.25);
    transform: scale(1.1);
}

.cart-info-icon svg {
    width: 14px;
    height: 14px;
}

.cart-beta-tag {
    font-size: 8px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 1px 4px;
    border-radius: 999px;
    background: rgba(244, 192, 60, 0.2);
    color: #B45309;
    display: inline-block;
    vertical-align: baseline;
    line-height: 1.2;
}

/* Mobile-specific header adjustments */
@media (max-width: 639px) {
    .header-logo-wrapper {
        min-width: 30px;
        min-height: 30px; /* Matches mobile logo height (30px) */
        margin-right: 0; /* No extra margin on mobile - logo and name close together */
        /* Wrapper visibility controlled by brand-config-loader - hidden until logo loads */
    }
    
    .header-logo-wrapper[style*="display: flex"],
    .header-logo-wrapper:not([style*="display: none"]) {
        display: flex;
    }
    
    .header-logo {
        height: 30px; /* Increased by 2px from 28px - Slightly smaller on mobile for better fit */
        max-width: 100px;
        min-width: 24px;
        /* Logo visibility controlled by brand-config-loader */
    }
    
    .header-brand-group {
        gap: var(--space-1); /* Minimal spacing on mobile - logo and name side by side */
        /* Ensure brand group is visible */
        display: flex !important;
    }
}

/* Mobile Responsive Header */
@media (min-width: 640px) {
.app-header {
    /* Keep fixed positioning on all screen sizes */
    --nav-h: 60px;
}

.header-container {
    padding: var(--space-3) var(--space-6);
    min-height: 60px; /* Slightly taller on tablet/desktop */
}

.header-brand-group {
    gap: var(--space-1); /* Minimal spacing - logo and name appear side by side */
}

.header-logo-wrapper {
    min-width: 38px; /* Matches tablet/desktop logo height (38px) */
    min-height: 38px;
}
            
.header-logo {
    height: 38px; /* Increased by 2px from 36px - Slightly larger on bigger screens */
    max-width: 140px;
}
            
.header-title-group h1 {
    font-size: 20px; /* Larger on bigger screens */
}
            
.header-title-group p {
    font-size: 13px;
}

.category-filter-container {
    margin: var(--space-3) var(--space-6) var(--space-3);
    border-radius: 24px;
    margin-bottom: 0 !important; /* Removed to prevent coral stripe */
    /* Consistent spacing on desktop (Apple HIG: 24px) */
    /* Spacing now handled by products-container margin-top */
}

.category-filter-btn {
    min-width: 240px; /* Slightly wider on larger screens */
    font-size: 15px; /* Slightly larger on bigger screens */
}
}

/* Tab content */
.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

/* =====================================================
MAIN CONTENT AREA - SCROLLABLE BETWEEN FIXED HEADER AND NAV
===================================================== */
.main-content {
    position: relative;
    width: 100%;
    /* Header is now fixed, so content starts below it */
    /* No top padding needed - body handles it */
    min-height: calc(100vh - 128px - 68px); /* Account for fixed header (128px: 56px + 72px) and bottom nav (68px) */
    overflow-x: hidden;
    overflow-y: visible;
    /* Ensure content is scrollable */
    -webkit-overflow-scrolling: touch;
}

@media (min-width: 640px) {
    .main-content {
        min-height: calc(100vh - 132px - 76px); /* Slightly taller header on larger screens */
    }
}

/* =====================================================
BOTTOM NAVIGATION - STRIPE ULTRACLEAN STYLE
===================================================== */
.bottom-nav {
    position: fixed !important;
    bottom: 0 !important;
    left: 0;
    right: 0;
    z-index: 10002 !important; /* Always on top - above search sheet (10000) */
    display: flex;
    justify-content: center;
    align-items: center;
    padding: var(--space-2) var(--space-4);
            /* Enhanced glassmorphism effect */
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
            /* Enhanced border for better visibility */
    border-top: 2px solid rgba(107, 114, 128, 0.15);
            /* Subtle gradient border effect */
    box-shadow: 
    0 -1px 0 rgba(255, 255, 255, 0.5) inset,
    0 -4px 16px rgba(0, 0, 0, 0.12),
    0 -2px 8px rgba(107, 114, 128, 0.08);
}

.bottom-nav .glass-radio-group {
    display: flex;
    width: 100%;
    max-width: 480px;
            /* Subtle glass effect */
    background: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    border-radius: var(--radius-xl);
    padding: var(--space-1);
    gap: var(--space-1);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.glass-radio-group input {
    display: none;
}

.glass-radio-group label {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: var(--space-2) var(--space-1);
    cursor: pointer;
    color: var(--text-secondary);
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 0.01em;
    border-radius: var(--radius-lg);
    transition: all 0.2s var(--ease-stripe);
    position: relative;
    min-width: 0;
    overflow: visible;
    gap: 2px;
}

.glass-radio-group label svg {
    width: 20px;
    height: 20px;
    margin-bottom: 0;
    transition: all 0.2s var(--ease-stripe);
    flex-shrink: 0;
}

.glass-radio-group label:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.6);
}

.glass-radio-group input:checked + label {
            /* Brand secondary color gradient highlight for active tab */
    color: #FFFFFF;
    background: var(--gradient-accent, linear-gradient(135deg, rgba(255, 180, 60, 0.95) 0%, rgba(255, 200, 100, 0.95) 50%, rgba(255, 220, 140, 0.95) 100%));
    box-shadow: 
    0 4px 12px rgba(107, 114, 128, 0.35),
    0 2px 4px rgba(107, 114, 128, 0.25);
    font-weight: 600;
}

.glass-radio-group input:checked + label svg {
    transform: translateY(-1px);
    filter: brightness(0) invert(1); /* Make icon white */
}

.glass-radio-group label span {
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 0.01em;
    white-space: nowrap;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 3px;
    line-height: 1.2;
    text-align: center;
    min-height: 14px;
}

.glass-radio-group label span .cart-beta-tag {
    font-size: 8px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 1px 4px;
    border-radius: 999px;
    background: rgba(244, 192, 60, 0.2);
    color: #B45309;
    display: inline-block;
    vertical-align: baseline;
    line-height: 1.2;
    margin-left: 2px;
}

.glass-radio-group label .relative {
    position: relative;
}

.glass-glider {
    display: none;
}

@media (min-width: 640px) {
.bottom-nav {
    padding: var(--space-3) var(--space-6);
}
            
.glass-radio-group label {
    padding: var(--space-3) var(--space-4);
    font-size: 12px;
}
            
.glass-radio-group label svg {
    width: 22px;
    height: 22px;
}
}